home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Visual Basic Source Code
/
Visual Basic Source Code.iso
/
vbsource
/
nagscrn
/
nagscrn.frm
(
.txt
)
< prev
next >
Wrap
Visual Basic Form
|
1997-06-15
|
7KB
|
201 lines
VERSION 4.00
Begin VB.Form frmNag
Appearance = 0 'Flat
BackColor = &H80000005&
Caption = "Nag Screen & Registration Information"
ClientHeight = 3750
ClientLeft = 1950
ClientTop = 1485
ClientWidth = 6510
BeginProperty Font
name = "MS Sans Serif"
charset = 1
weight = 700
size = 8.25
underline = 0 'False
italic = 0 'False
strikethrough = 0 'False
EndProperty
ForeColor = &H80000008&
Height = 4155
Left = 1890
LinkTopic = "Form1"
MaxButton = 0 'False
ScaleHeight = 3750
ScaleWidth = 6510
Top = 1140
Width = 6630
Begin Threed.SSPanel pnlMain
Height = 3750
Left = 0
TabIndex = 1
Top = 0
Width = 6510
_version = 65536
_extentx = 11483
_extenty = 6615
_stockprops = 15
backcolor = -2147483633
bevelouter = 0
Begin Threed.SSPanel RegPanel
Height = 720
Left = 990
TabIndex = 4
Top = 1755
Width = 4620
_version = 65536
_extentx = 8149
_extenty = 1270
_stockprops = 15
backcolor = -2147483633
bevelouter = 0
bevelinner = 1
Begin Threed.SSCommand RegButton
Height = 600
Left = 60
TabIndex = 5
Top = 60
Width = 4485
_version = 65536
_extentx = 7911
_extenty = 1058
_stockprops = 78
caption = "Register Here"
BeginProperty font {FB8F0823-0164-101B-84ED-08002B2EC713}
name = "MS Sans Serif"
charset = 1
weight = 400
size = 8.25
underline = 0 'False
italic = 0 'False
strikethrough = 0 'False
EndProperty
End
End
Begin Threed.SSPanel pnlButton
Height = 720
Left = 975
TabIndex = 2
Top = 2550
Width = 4620
_version = 65536
_extentx = 8149
_extenty = 1270
_stockprops = 15
backcolor = -2147483633
bevelouter = 0
bevelinner = 1
Begin Threed.SSCommand btnExit
Height = 600
Left = 60
TabIndex = 3
Top = 60
Width = 4485
_version = 65536
_extentx = 7911
_extenty = 1058
_stockprops = 78
caption = "Exit Program"
BeginProperty font {FB8F0823-0164-101B-84ED-08002B2EC713}
name = "MS Sans Serif"
charset = 1
weight = 400
size = 8.25
underline = 0 'False
italic = 0 'False
strikethrough = 0 'False
EndProperty
End
End
Begin VB.Label Label9
Alignment = 2 'Center
Appearance = 0 'Flat
BackColor = &H80000005&
Caption = "UNREGISTERED COPY"
ForeColor = &H000000FF&
Height = 195
Left = 2265
TabIndex = 7
Top = 1155
Width = 2040
End
Begin VB.Label Label1
Appearance = 0 'Flat
BackColor = &H80000005&
Caption = "This program is registered to:"
ForeColor = &H80000008&
Height = 195
Left = 2070
TabIndex = 6
Top = 885
Width = 2490
End
Begin VB.Label lblMain
Appearance = 0 'Flat
AutoSize = -1 'True
BackColor = &H80000005&
Caption = $"NAGSCRN.frx":0000
BeginProperty Font
name = "MS Sans Serif"
charset = 1
weight = 400
size = 8.25
underline = 0 'False
italic = 0 'False
strikethrough = 0 'False
EndProperty
ForeColor = &H0000FFFF&
Height = 585
Left = 2055
TabIndex = 0
Top = 135
Width = 2610
WordWrap = -1 'True
End
End
Attribute VB_Name = "frmNag"
Attribute VB_Creatable = False
Attribute VB_Exposed = False
Private Sub btnExit_Click()
' Registration information is written to .INI file here.
I% = WritePrivateProfileString("Registration Info", "Serial", RegStat, INIFILENAME$)
I% = WritePrivateProfileString("Registration Info", "FirstName ", First, INIFILENAME$)
I% = WritePrivateProfileString("Registration Info", "LastName", Last, INIFILENAME$)
' If no registration information is entered, second "nag"
' screen is displayed here.
If RegStat <> SerialNum$ Then
frmTimr2.Show 1
End If
Unload Me
End Sub
Private Sub Form_Load()
'Center form on screen.
Left = (Screen.Width - Width) \ 2
Top = (Screen.Height - Height) \ 2
' Get registration information from NAGSCRN.INI.
RegStat = Space$(31)
I% = GetPrivateProfileString("Registration Info", "Serial", "Unregistered Copy", RegStat, 30, INIFILENAME$)
RegStat = Left$(RegStat, I%)
RegStat = LTrim$(RTrim$(RegStat))
First = Space(31)
I% = GetPrivateProfileString("Registration Info", "FirstName", "First Name", First, 30, INIFILENAME$)
First = Left$(First, I%)
First = LTrim$(RTrim$(First))
Last = Space(31)
I% = GetPrivateProfileString("Registration Info", "LastName", "Last Name", Last, 30, INIFILENAME$)
Last = Left$(Last, I%)
Last = LTrim$(RTrim$(Last))
If RegStat = SerialNum$ Then
RegPanel.Visible = False
RegButton.Visible = False
Label9.Caption = First + " " + Last
Label9.ForeColor = &H800000
Else
' If registration information is not entered, "nag" screens are displayed here.
frmTimer.Show 1
End If
End Sub
Private Sub RegButton_Click()
RegNum.Show
End Sub